package StudyCode.summary.BufferAndChannel;

import java.nio.ByteBuffer;

/**
 * 版权所有 科技与人文(www.tah1986.com)
 */
public class ByteBufferPutShort {
	public static void main(String[] args) {
		ByteBuffer buf = ByteBuffer.allocate(100);
		buf.putShort((short) 123);
		buf.flip();
		System.out.println("从 ByteBuffer 获取写入的 Short:" + buf.getShort());
	}
}
